<template>
  <div class="page">
    <el-button @click="login">
      登录
    </el-button>
  </div>
</template>

<script>
export default {
  name: 'Login',
  data() {
    return {}
  },
  methods: {
    login() {
      this.$store.dispatch('user/login').then(res => {
        this.$router.push('/user')
      })
    }
  }
}
</script>

<style scoped lang="scss">
</style>
